/**
 * 
 */
package org.rrest.core.configuration;

import org.rrest.core.filesystem.FileSystemManager;
import org.rrest.core.filesystem.impl.FileSystemManagerImpl;
import org.springframework.context.annotation.Bean;
import org.springframework.context.annotation.Configuration;
import org.springframework.remoting.rmi.RmiServiceExporter;

@Configuration
public class RmiExporter {

	@Bean(name = "fileSystemRmi")
	public RmiServiceExporter getRmiMainService() {
		RmiServiceExporter rmi = new RmiServiceExporter();
		rmi.setServiceInterface(FileSystemManager.class);
		rmi.setServiceName("fileSystemManager");
		rmi.setService(new FileSystemManagerImpl());
		return rmi;
	}

}
